<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:context="http://www.springframework.org/schema/context"
	xsi:schemaLocation="http://www.springframework.org/schema/beans
    http://www.springframework.org/schema/beans/spring-beans-3.1.xsd
    http://www.springframework.org/schema/context
    http://www.springframework.org/schema/context/spring-context-3.1.xsd">

	<!-- Define o pacote inicial que é considerado por este contexto. -->
	<context:component-scan base-package="br.com.news.service" />
	
	<bean id="remoteUsuarioService" class="br.com.news.service.UsuarioService" />
	<bean id="remoteAcessoNoticiaService" class="br.com.news.service.AcessoNoticiaService" />
	<bean id="remoteAlternativaEnqueteService" class="br.com.news.service.AlternativaEnqueteService" />
	<bean id="remoteAuditoriaService" class="br.com.news.service.AuditoriaService" />
	<bean id="remoteCategoriaService" class="br.com.news.service.CategoriaService" />
	<bean id="remoteComentarioService" class="br.com.news.service.ComentarioService" />
	<bean id="remoteContatoService" class="br.com.news.service.ContatoService" />
	<bean id="remoteEmailIndicacaoService" class="br.com.news.service.EmailIndicacaoService" />
	<bean id="remoteEnqueteService" class="br.com.news.service.EnqueteService" />
	<bean id="remoteFonteService" class="br.com.news.service.FonteService" />
	<bean id="remoteNoticiaService" class="br.com.news.service.NoticiaService" />
	<bean id="remoteRespostaEnqueteService" class="br.com.news.service.RespostaEnqueteService" />
	<bean id="remoteUsuarioAndroidService" class="br.com.news.service.UsuarioAndroidService" />
	<bean id="remoteUsuarioTipoService" class="br.com.news.service.UsuarioTipoService" />
	<bean id="remoteAnuncioService" class="br.com.news.service.AnuncioService" />
	<bean id="remoteCategoriaUsuarioService" class="br.com.news.service.CategoriaUsuarioService" />
	
	<!-- Define o arquivo que é usado para buscar as informações de configuração. -->
	<bean class="org.springframework.beans.factory.config.PreferencesPlaceholderConfigurer">
		<property name="location" value="file:./conf/news-conf.properties" />
	</bean>
	
	<bean class="org.springframework.remoting.rmi.RmiServiceExporter">
		<property name="serviceName" value="remote-usuario-service" />
		<property name="service" ref="remoteUsuarioService" />
		<property name="serviceInterface" value="br.com.news.utils.service.interfaces.IUsuarioService" />
		<property name="registryPort" value="${remote.service.rmi.port}" />
	</bean>
	
	<bean class="org.springframework.remoting.rmi.RmiServiceExporter">
		<property name="serviceName" value="remote-acesso-noticia-service" />
		<property name="service" ref="remoteAcessoNoticiaService" />
		<property name="serviceInterface" value="br.com.news.utils.service.interfaces.IAcessoNoticiaService" />
		<property name="registryPort" value="${remote.service.rmi.port}" />
	</bean>
	
	<bean class="org.springframework.remoting.rmi.RmiServiceExporter">
		<property name="serviceName" value="remote-alternativa-enquete-service" />
		<property name="service" ref="remoteAlternativaEnqueteService" />
		<property name="serviceInterface" value="br.com.news.utils.service.interfaces.IAlternativaEnqueteService" />
		<property name="registryPort" value="${remote.service.rmi.port}" />
	</bean>
	
	<bean class="org.springframework.remoting.rmi.RmiServiceExporter">
		<property name="serviceName" value="remote-auditoria-service" />
		<property name="service" ref="remoteAuditoriaService" />
		<property name="serviceInterface" value="br.com.news.utils.service.interfaces.IAuditoriaService" />
		<property name="registryPort" value="${remote.service.rmi.port}" />
	</bean>
	
	<bean class="org.springframework.remoting.rmi.RmiServiceExporter">
		<property name="serviceName" value="remote-categoria-service" />
		<property name="service" ref="remoteCategoriaService" />
		<property name="serviceInterface" value="br.com.news.utils.service.interfaces.ICategoriaService" />
		<property name="registryPort" value="${remote.service.rmi.port}" />
	</bean>
	
	<bean class="org.springframework.remoting.rmi.RmiServiceExporter">
		<property name="serviceName" value="remote-comentario-service" />
		<property name="service" ref="remoteComentarioService" />
		<property name="serviceInterface" value="br.com.news.utils.service.interfaces.IComentarioService" />
		<property name="registryPort" value="${remote.service.rmi.port}" />
	</bean>
	
	<bean class="org.springframework.remoting.rmi.RmiServiceExporter">
		<property name="serviceName" value="remote-contato-service" />
		<property name="service" ref="remoteContatoService" />
		<property name="serviceInterface" value="br.com.news.utils.service.interfaces.IContatoService" />
		<property name="registryPort" value="${remote.service.rmi.port}" />
	</bean>
	
	<bean class="org.springframework.remoting.rmi.RmiServiceExporter">
		<property name="serviceName" value="remote-email-indicacao-service" />
		<property name="service" ref="remoteEmailIndicacaoService" />
		<property name="serviceInterface" value="br.com.news.utils.service.interfaces.IEmailIndicacaoService" />
		<property name="registryPort" value="${remote.service.rmi.port}" />
	</bean>
	
	<bean class="org.springframework.remoting.rmi.RmiServiceExporter">
		<property name="serviceName" value="remote-enquete-service" />
		<property name="service" ref="remoteEnqueteService" />
		<property name="serviceInterface" value="br.com.news.utils.service.interfaces.IEnqueteService" />
		<property name="registryPort" value="${remote.service.rmi.port}" />
	</bean>
	
	<bean class="org.springframework.remoting.rmi.RmiServiceExporter">
		<property name="serviceName" value="remote-fonte-service" />
		<property name="service" ref="remoteFonteService" />
		<property name="serviceInterface" value="br.com.news.utils.service.interfaces.IFonteService" />
		<property name="registryPort" value="${remote.service.rmi.port}" />
	</bean>
	
	<bean class="org.springframework.remoting.rmi.RmiServiceExporter">
		<property name="serviceName" value="remote-noticia-service" />
		<property name="service" ref="remoteNoticiaService" />
		<property name="serviceInterface" value="br.com.news.utils.service.interfaces.INoticiaService" />
		<property name="registryPort" value="${remote.service.rmi.port}" />
	</bean>
	
	<bean class="org.springframework.remoting.rmi.RmiServiceExporter">
		<property name="serviceName" value="remote-resposta-enquete-service" />
		<property name="service" ref="remoteRespostaEnqueteService" />
		<property name="serviceInterface" value="br.com.news.utils.service.interfaces.IRespostaEnqueteService" />
		<property name="registryPort" value="${remote.service.rmi.port}" />
	</bean>
	
	<bean class="org.springframework.remoting.rmi.RmiServiceExporter">
		<property name="serviceName" value="remote-usuario-android-service" />
		<property name="service" ref="remoteUsuarioAndroidService" />
		<property name="serviceInterface" value="br.com.news.utils.service.interfaces.IUsuarioAndroidService" />
		<property name="registryPort" value="${remote.service.rmi.port}" />
	</bean>
	
	<bean class="org.springframework.remoting.rmi.RmiServiceExporter">
		<property name="serviceName" value="remote-usuario-tipo-service" />
		<property name="service" ref="remoteUsuarioTipoService" />
		<property name="serviceInterface" value="br.com.news.utils.service.interfaces.IUsuarioTipoService" />
		<property name="registryPort" value="${remote.service.rmi.port}" />
	</bean>
	
	<bean class="org.springframework.remoting.rmi.RmiServiceExporter">
		<property name="serviceName" value="remote-anuncio-service" />
		<property name="service" ref="remoteAnuncioService" />
		<property name="serviceInterface" value="br.com.news.utils.service.interfaces.IAnuncioService" />
		<property name="registryPort" value="${remote.service.rmi.port}" />
	</bean>
	
	<bean class="org.springframework.remoting.rmi.RmiServiceExporter">
		<property name="serviceName" value="remote-categoria-usuario-service" />
		<property name="service" ref="remoteCategoriaUsuarioService" />
		<property name="serviceInterface" value="br.com.news.utils.service.interfaces.ICategoriaUsuarioService" />
		<property name="registryPort" value="${remote.service.rmi.port}" />
	</bean>
	
</beans>
